package com.niubility.server.Impl;


import com.niubility.dao.MessageDao;
import com.niubility.entity.Message;
import com.niubility.server.IMessageServer;
import com.niubility.vo.GoodLoad;
import com.niubility.vo.MessageShow;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service("messageServer")
public  class MessageServer implements IMessageServer{
    @Resource
    private MessageDao messageDao;
    public Message Select(int mesId){
        return messageDao.Select(mesId);
    }
    public List<MessageShow> MessageSelect(int mesMainid, int mark){
        return  messageDao.MessageSelect(mesMainid,mark);
    }
    public int Delete(int mesId){
        return messageDao.Delete(mesId);
    }
    public int Save(Message message){
        return messageDao.Save(message);
    }
    public List<Message> ByldAll(int mesMianid){
        return messageDao.ByldAll(mesMianid);
    }
    public int DeleteAll(int mesMianid){
        return messageDao.DeleteAll(mesMianid);
    }
//    public int SelectByAssess(int userId,int artId){//张晨
//        return  messageDao.SelectByAssess(userId,artId);
//    }  //此方法已不用
    public int  MessageInsert(Message message){//张晨
        return messageDao.MessageInsert(message);
    }

    public int MessageDelete(int mesMainid,int mesSendid,int artId){//张晨
        return messageDao.MessageDelete(mesMainid,mesSendid,artId);
    }

    public int InsertMessage(Message message){
        return messageDao.InsertMessage(message);//张家乐  徐松鹤
    }

    public int SelectAssessMark(int mesMainid,int mesSendid,int artId){     //张晨
        return messageDao.SelectAssessMark(mesMainid,mesSendid,artId);
    }

    public List<GoodLoad> GoodLoadById(Integer usersId) {
        return messageDao.GoodLoadById(usersId);
    }
}

